#ifndef JSLIDEENGINE_H
#define JSLIDEENGINE_H

#include <QTEGui/qteguiglobal.h>

class QPoint;
class QMouseEvent;
class QAbstractScrollArea;

namespace QTE
{

class JScrollAreaUVLMEnginePrivate;

// JUVLMEngine

class QTEGUI_EXPORT JScrollAreaUVLMEngine
{
protected:
	explicit JScrollAreaUVLMEngine(QAbstractScrollArea *scrollArea, bool autoScrollBar = true);
	virtual ~JScrollAreaUVLMEngine();

public Q_SLOTS:
	void setAutoScrollBar(bool enable = true);
	void setUVLMEEnabled(bool enable);

public:
	bool autoScrollBar();
	bool isUVLMEEnabled();

public:
	static void bind(QAbstractScrollArea *scrollArea, bool autoScrollBar = true);
	static void unbound(const QAbstractScrollArea *scrollArea);
	static void setAutoScrollBar(const QAbstractScrollArea *scrollArea, bool enable = true);
	static void setUVLMEEnabled(const QAbstractScrollArea *scrollArea, bool enable);
	static void setRefreshRate(int rate);

	static bool isBind(const QAbstractScrollArea *scrollArea);
	static bool autoScrollBar(const QAbstractScrollArea *scrollArea);
	static bool isUVLMEEnabled(const QAbstractScrollArea *scrollArea);
	static int refreshRate();

private:
	JScrollAreaUVLMEnginePrivate *d_ptr;
	Q_DISABLE_COPY(JScrollAreaUVLMEngine)
};

} //namespace QTE


#endif //JSLIDEENGINE_H
